/*package com.laowang.framework.redis;

import com.laowang.project.system.controller.TbAppUserController;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.data.redis.connection.RedisConnectionFactory;
import org.springframework.data.redis.listener.ChannelTopic;
import org.springframework.data.redis.listener.RedisMessageListenerContainer;
import org.springframework.data.redis.listener.adapter.MessageListenerAdapter;

*//**
 * @Author: laowang
 * @Date: 2020/10/20
 * @Description 创建监听消息的容器
 *//*
@Configuration
public class MyRedisMessageListenerContainer {

    @Autowired
    private RedisMessageListener redisMessageListener;

    @Bean
    public MessageListenerAdapter messageListener() {
        return new MessageListenerAdapter(redisMessageListener);
    }

    @Bean
    RedisMessageListenerContainer redisContainer(RedisConnectionFactory factory) {
        final RedisMessageListenerContainer container = new RedisMessageListenerContainer();
        container.setConnectionFactory(factory);
        container.addMessageListener(messageListener(),*//*new ChannelTopic("channel")*//* TbAppUserController.channelList);// 监听的通道 必须事先定义好
        return container;
    }

}*/
